package com.egao.gzh.controller;

import com.alibaba.fastjson.JSONObject;
import com.egao.common.core.Constants;
import com.egao.common.core.damon.constant.WechatConstant;
import com.egao.common.core.damon.utils.HttpClientUtil;
import com.egao.common.core.security.JwtUtil;
import com.egao.common.core.web.BaseController;
import com.egao.common.core.web.JsonResult;
import com.egao.common.system.entity.User;
import com.egao.common.system.service.LoginRecordService;
import com.egao.common.system.service.UserService;
import com.egao.gzh.service.Wxservice;
import com.egao.gzh.utils.AesException;
import com.egao.gzh.utils.WXPublicUtils;
import io.swagger.annotations.ApiOperation;
import org.dom4j.DocumentException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.HashMap;
import java.util.Map;

/**
 * @author : Doman
 * @version ：1.0
 * @date : 2020-04-12 17:33
 */
@RestController
@RequestMapping("/api/gzh")
public class GzhWithTokenController extends BaseController {

    /**
     *  验证小程序的token有没有过期
     */
    @PostMapping("/auth")
    public JsonResult updateMyInfo( HttpServletRequest request) {
        User a = getLoginUser();
        return JsonResult.ok("已登陆");
    }
}